<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE HTML>
<html class="">
<head>
	
	<meta name="author" content="蓝凌科技">
	<meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
	<meta name="format-detection" content="telephone=no">
	<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
	<meta http-equiv="Pragma" content="no-cache" />
	<meta http-equiv="Expires" content="0" />

	<link rel="stylesheet" type="text/css" href="/Public/Api/css/sm.min.css">	
	<link rel="stylesheet" type="text/css" href="/Public/Api/css/sm-extend.min.css">	
	
	<title>帮工小哥</title>
	
	<script type="text/javascript">
	    var _root = '<?php echo ($_site_url); echo U(' / ');?>', _controller = '<?php echo ($_controller); ?>';
	</script>
	
	
	<link rel="stylesheet" type="text/css" href="/Public/Api/css/custom.css">


</head>
<body>
	
	

<div class="page-group">
    <div class="page page-custom page-current">
        <header class="recommend-man">
            <img class="avatar" src="<?php echo ((isset($workerModel['fullpath']) && ($workerModel['fullpath'] !== ""))?($workerModel['fullpath']):'/Public/Api/images/avatar.png'); ?>">
            <input type="hidden" name="worker_id" id="worker_id" value="<?php echo ($workerModel['worker_id']); ?>"/>
            <input type="hidden" name="lastIndex" id="lastIndex" value="0"/>
            <div class="info">
                <div class="table">
                    <div class="cell name"><?php echo ($workerModel['name']); ?>-<?php echo ($workerModel['account']); ?></div>
                    <div class="cell full evaluate">
                    	<?php if(!empty($workerModel['score'])): $__FOR_START_920511827__=0;$__FOR_END_920511827__=5;for($i=$__FOR_START_920511827__;$i < $__FOR_END_920511827__;$i+=1){ if($workerModel['score']/2 > $i): ?><span class="heart"></span><?php endif; } ?>
					    <?php else: ?>
					    	<span class="heart"></span><?php endif; ?>
                    </div>
                </div>
                <div class="table">
                    <div class="cell">工号 : <?php echo ($workerModel['eid']); ?></div>
                </div>
                <div class="table">
                    <div class="cell">工种 : <?php echo get_dictionary_enum_name('profession_options', $workerModel['profession']);?></div>
                    <div class="cell full text-right"><?php echo ((isset($workerModel['orders_sum']) && ($workerModel['orders_sum'] !== ""))?($workerModel['orders_sum']):'0'); ?> 单</div>
                </div>
                <div class="table-layout">
                    <div class="cell">从业年数 : <?php echo ((isset($workerModel['work_year']) && ($workerModel['work_year'] !== ""))?($workerModel['work_year']):'1'); ?> 年</div>
                    <div class="cell full text-right"><?php echo ($total); ?> 人点评</div>
                </div>
            </div>
        </header>
        <div class="content">
            <div class="buttons-tab">
                <a href="#tab1" class="tab-link active button">小哥简介</a>
                <a href="#tab2" class="tab-link button">用户评价</a>
            </div>
            <div class="content-custom">
                <div class="tabs">
                    <div id="tab1" class="tab active">
                        <ul class="list-unstyled man-list">
                            <?php echo (htmlspecialchars_decode($workerModel['description'])); ?>
                        </ul>
                    </div>
                    <div id="tab2" class="tab infinite-scroll">
                        <div class="list-comment">
                        </div>
                        
                        <!-- 加载提示符 -->
	                    <div class="infinite-scroll-preloader">
							<div class="preloader">
	                      	</div>
	                    </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>




	<!-- 底部
================================================== -->
<footer>
</footer>
<script type="text/javascript">
    (function(){
        var ThinkPHP = window.Think = {
            "ROOT"   : "", //当前网站地址
            "APP"    : "/api.php?s=", //当前项目地址
            "PUBLIC" : "/Public", //项目公共目录地址
            "DEEP"   : "<?php echo C('URL_PATHINFO_DEPR');?>", //PATHINFO分割符
            "MODEL"  : ["<?php echo C('URL_MODEL');?>", "<?php echo C('URL_CASE_INSENSITIVE');?>", "<?php echo C('URL_HTML_SUFFIX');?>"],
            "VAR"    : ["<?php echo C('VAR_MODULE');?>", "<?php echo C('VAR_CONTROLLER');?>", "<?php echo C('VAR_ACTION');?>"]
        }
    })();
    
</script>
<script src="/Public/Api/js/zepto.min.js" type="text/javascript">
</script>
<script type="text/javascript">
//坑死人的配置项
//若不加此配置，则所有页面均使用 js 和 css 缓存
$.config = {
   	router: false
}
</script>
<script src="/Public/Api/js/sm.min.js" type="text/javascript">
</script>
<script src="/Public/Api/js/sm-extend.min.js" type="text/javascript">
</script>
<script src="/Public/Api/js/think.js" type="text/javascript">
</script>


<script type="text/javascript">

var target = Think.U('Worker/ajax_evaluationList');
var params = ['lastIndex', 'worker_id'];
var container = '#tab2 .list-comment';

$("#lastIndex").val('0');

function joinHTML(data){
	
	var html = '';
	var photoURL = './Public/Api/images/icon-user2.png';
	var star = '';
	
	$.each(data, function(key, val){
		
		photoURL = val['fullpath'] ? val['fullpath'] : photoURL;
		star = '';
		
		for (var i=0;i<5;i++){
			if(val['score']/2 > i){
				star += '<span class="heart"></span>';
			}
		}
		
		html += '<div class="comment"><div class="comment-header"><img class="avatar" src="' + photoURL + '">';
		html += '<div class="info"><div class="name">' + val['username'] + '</div><div class="evaluate">' + star;
		html += '</div></div></div><div class="comment-body">' + val['content'] + '</div><div class="comment-footer">';
		html += formatDate(val['create_time']) + '</div></div>';
		
	});
	
	return html;
}

</script>

<script src="/Public/Api/js/pageLoading.js" type="text/javascript"></script>

<!-- 用于加载js代码 -->

</body>
</html>